package com.dk.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.stereotype.Component;
import sun.security.krb5.internal.PAData;

import java.util.Date;

/*
* @ConfigurationProperties :全量加载配置文件中的值,一般次注解用在配置类中 XXXproperties类中
* */
@Component
@ConfigurationProperties(prefix = "user")
public class User {
    private  Integer id ;
    private  String  username;
    private  String sex;
    private Date birth;
    private String nikey;//昵称
    private Integer cid ;

    public User(Integer id, String username, String sex, Date birth, String nikey, Integer cid) {
        this.id = id;
        this.username = username;
        this.sex = sex;
        this.birth = birth;
        this.nikey = nikey;
        this.cid = cid;
    }

    public Integer getCid() {
        return cid;
    }

    public void setCid(Integer cid) {
        this.cid = cid;
    }

    public User(Integer id, String username, String sex, Date birth, String nikey) {
        this.id = id;
        this.username = username;
        this.sex = sex;
        this.birth = birth;
        this.nikey = nikey;
    }
    public User() {
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public Date getBirth() {
        return birth;
    }

    public void setBirth(Date birth) {
        this.birth = birth;
    }

    public String getNikey() {
        return nikey;
    }

    public void setNikey(String nikey) {
        this.nikey = nikey;
    }
}
